#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
int fib (int d);
int main()
{
	int d = 1;
	int re = 0;
	scanf("%d", &d);
	re = fib(d);
	printf("%d",re );
	return 0;
}
int fib(int d)
{
	if (d <= 2)
		return 1;
	else
		return  fib(d - 1) + fib(d - 2);
}